﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace CaramelEngine
{

    // NOTE: Territories themselves are pretty good at the moment, I think.
    // TODO: We do need more types of territories made for the 'preset/base' items

    public interface ITerritory : ITargetable
    {
      Guid ID { get; set; }
      string Name { get; set; }
        //List<ITerritory> ConnectedTerritories { get; set; }       
    }

    public class Territory<T, P> : ITerritory, IControllable<P>
    {
        public List<T> ConnectedTerritories
        {
            get;
            set;
        }

        #region ITerritory Members

        public Guid ID
        {
            get;            
            set;            
        }

        public string Name
        {
            get;
            set;
        }        

        #endregion

        public Territory()
        {
            ID = Guid.NewGuid();            
            ConnectedTerritories = new List<T>();            
        }

        public Territory(string territoryName)
        {
            ID = Guid.NewGuid();
            Name = territoryName;            
            ConnectedTerritories = new List<T>();            
        }

        #region IControllable<T> Members

        public P Owner
        {
            get;
            set;
        }

        public P Controller
        {
            get;
            set;
        }

        #endregion
    }
}
